package vboot.core.module.sys.api.main;

import lombok.Data;
import vboot.core.module.sys.portal.menu.SysPortalMenu;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Transient;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;

@Entity
@Data
public class SysApiMain {

    @Id
    @Column(length = 64)
    private String id;//接口ID

    @Column(length = 64)
    private String name;//接口名称

    @Column(length = 64)
    private String pid;//上级ID

    @Column(length = 64)
    private String url;//接口url

    private Long code;//权限代码

    private Integer pos;//权限位

//    private Boolean cotag;//公共标记

    @Column(length = 32)
    private String type;//权限类型

    private Boolean avtag;//可用标记

    private String notes;//备注

    @Column(updatable = false)
    private Date crtim = new Date();//创建时间

    private Date uptim ;//更新时间

    @Transient
    private List<SysApiMain> children = new ArrayList<>();

}
